import request from '@/utils/request'


// 出入库明细请求地址
export function Churukumingxi(a) {
  return request({
    url: `/wrapper/cgreport/getData/1573695541629427714?_t=${a}&column=bill_date&order=asc&field=id,,,bill_no,bill_date,stock_io_type_dictText,customer_id_dictText,supplier_id_dictText,material_code,material_name,material_model,batch_no,warehouse_id_dictText,unit_id_dictText,in_qty,in_cost,out_qty,out_cost,unit_cost,undefined&pageNo=1&pageSize=10`,
    method: 'get',

  })
}
//   export function Churukumingxisousuo(a, column, order, field, pageNo, pageSize) {
//     return request({
//       url: `/wrapper/cgreport/getData/1573695541629427714?_t=${a}&column=${column}&order=${order}&field=${field}&pageNo=${pageNo}&pageSize=${pageSize}`,
//       method: 'get',

//     })
//   }

//出入库明细查询地址
export function Churukumingxisousuo(params) {
  const eeear = new URLSearchParams(params)
  return request({
    url: `/wrapper/cgreport/getData/1573695541629427714?` + eeear,
    method: 'get',
  })
}
// 出入库日汇总接口
export function Chururihuizong(params) {
  const eeear = new URLSearchParams(params)
  return request({
    url: `/stock/stkStatistics/day/sum/wmb/list?` + eeear,
    method: 'get',
  })
}
// 出入库月汇总接口
export function Churuyuehuizong(params) {
  const eeear = new URLSearchParams(params)
  return request({
    url: `/wrapper/cgreport/getData/1575380033020686337?` + eeear,
    method: 'get',
  })
}
// 物料库存接口
export function Wuliaokucun(params) {
  const eeear = new URLSearchParams(params)
  return request({
    url: `/wrapper/cgreport/getData/1573315028393705474?` + eeear,
    method: 'get',
  })
}
// 物料批次库存接口
export function Wuliaopicikucun(params) {
  const eeear = new URLSearchParams(params)
  return request({
    url: `/wrapper/cgreport/getData/1572930989237252098?` + eeear,
    method: 'get',
  })
}
// 仓库物料库存接口
export function Cangkuwuliaokucun(params) {
  const eeear = new URLSearchParams(params)
  return request({
    url: `/wrapper/cgreport/getData/1573320640724779009?` + eeear,
    method: 'get',
  })
}
// 详细库存接口
export function Xiangxikucun(params) {
  const eeear = new URLSearchParams(params)
  return request({
    url: `/stock/stkInventory/list?` + eeear,
    method: 'get',
  })
}


// 库存调拨接口
export function Kucuntiaobo(params) {
  const eeear = new URLSearchParams(params)
  return request({
    url: `/stock/stkIo/list/301?` + eeear,
    method: 'get',
  })
}


//库存调拨删除接口
export const Diaoboshanchu = (id) => {
  return request({
    method: "put",
    url: "/stock/stkIo/void",
    data:{id},
  });
};
// 成本调整删除接口
export const chengbenshanchu = (id) => {
  return request({
    method: "put",
    url: "/stock/stkIo/void",
    data:{id},
  });
};
// 库存调拨用户点击获取接口
export function Diaoboyonghuhuoqu(params) {
  const eeear = new URLSearchParams(params)
  return request({
    url: `/sys/user/queryUserComponentData?` + eeear,
    method: 'get',
  })
}
// c成本调整获取接口
export function Chengbentiaozheng(params) {
  const eeear = new URLSearchParams(params)
  return request({
    url: `/stock/stkIo/list/801?` + eeear,
    method: 'get',
  })
}
// 库存盘点获取接口
export function Kucunpandian(params) {
  const eeear = new URLSearchParams(params)
  return request({
    url: `/stock/stkCheck/list?` + eeear,
    method: 'get',
  })
}
// 成本调整编辑
export const Cbtzbianji = (id) => {
  return request({
    method: "put",
    url: "/stock/stkIo/edit/submit",
    data:{id},
  });
};

